<?php
/**
 * Created by IntelliJ IDEA.
 * User: donglin
 * Date: 18/9/13
 * Time: 下午3:56
 */

spl_autoload_register(function ($class) {
    if ($class) {
        $file = str_replace('\\', '/', $class);
        $file .= '.php';
//        echo $file.'</br >';
        if (file_exists($file)) {
            include $file;
        }
    }
});
function dump($data) {
    echo '<pre>';
    var_dump($data);
    echo '</pre>';
}